# import socket

# host=socket.gethostname()
# ipaddress=socket.gethostbyname(host)
# print(host)
# print(ipaddress)




'''

import socket

#服务端
s = socket.socket(socket.AF_INET,socket.SOCK_STREAM)
s.bind(('127.0.0.1',8888))
s.listen(1)
conn,address = s.accept()
data = conn.recv(1024).decode('utf-8')
print(f'接收到客户端的数据:{data}')
conn.send('hello'.encode('utf-8'))
conn.close()
s.close()

#客户端

s_clint = socket.socket(socket.AF_INET,socket.SOCK_STREAM)
s_clint.connect(('127.0.0.1',8888))
s_clint.send('hello'.encode('utf-8'))
data=s_clint.recv(1024)
print(f'从服务器接收到消息{data.decode()}')
s_clint.close()





import socket

server_socket = socket.socket(socket.AF_INET,  socket.SOCK_DGRAM)
server_socket.bind(("127.0.0.1", 3456))
print("-------UDP聊天室-------")
while True:
    recv_info = server_socket.recvfrom(1024)
    address = recv_info[1][0] + ':' + str(recv_info[1][1])
    print("%s" % address)
    print("%s" % recv_info[0].decode())
    
server_socket.close()
'''



ds = {'eng':2,'math':6,'comp':9,'PE':4}
print(ds.pop(max(ds.keys()), 0))





